package com.zt.bigdata.elasticsearch.web.controller;

import com.ecfront.dew.common.$;

import java.io.Serializable;
import java.util.Date;

/**
 * 短链接实体类
 * Created by hzlizx on 2018/4/11 0011
 */
public class ShortUrl implements Serializable {

    //短链接ID
    private Long id;

    //创建时间
    private Date createdTime;

    //对应长链接
    private String longUrl;

    //是否删除 1-删除 0-没有删除
    private int delFlag;

    //状态 1-禁用 0-正常
    private int viewStatus;

    //过期时间
    private Date expired;

    //最大浏览量(超过则无法访问)
    private Integer maxView;

    //浏览量
    private Integer view;

    //创建人
    private String createdBy;

    public String getCreatedBy() {
        return createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Date getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Date createdTime) {
        this.createdTime = createdTime;
    }

    public String getLongUrl() {
        return longUrl;
    }

    public void setLongUrl(String longUrl) {
        this.longUrl = longUrl;
    }

    public int getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(int delFlag) {
        this.delFlag = delFlag;
    }

    public Date getExpired() {
        return expired;
    }

    public void setExpired(Date expired) {
        this.expired = expired;
    }

    public Integer getMaxView() {
        return maxView;
    }

    public void setMaxView(Integer maxView) {
        this.maxView = maxView;
    }

    public Integer getView() {
        return view;
    }

    public void setView(Integer view) {
        this.view = view;
    }

    public int getViewStatus() {
        return viewStatus;
    }

    public void setViewStatus(int viewStatus) {
        this.viewStatus = viewStatus;
    }

    @Override
    public String toString() {
        return $.json.toJsonString(this);
    }
}
